package br.ufrj.dcc.smarthotel.controls;

import br.ufrj.dcc.smarthotel.activities.RequestDetailActivity;
import br.ufrj.dcc.smarthotel.entities.Request;

public class RequestDetailControl extends Control {
	private RequestDetailActivity activity;
	
	public RequestDetailControl(RequestDetailActivity activity) {
		this.activity = activity;
	}

	public void loadRequestDetails(int clickedRequestId) {
		Request clickedRequest = (Request)this.retrieve(this.baseURI + "request/" + clickedRequestId, Request.class);
		this.activity.setClickedRequest(clickedRequest);
	}
}
